<template>
  <view class="package" v-for="(item,index) in orderLists" :key="item.id"
    @click="navTo('together/togetherDetail?id='+item.id)"
    :style="{marginTop:index===0?'0px':'15rpx'}">
    <view class="space-between" @click="copyText(item.order_sn)">
      <view>拼单号:{{item.order_sn}}
        <image src="../../static/index/copy.png" mode="" style="width:24rpx;height:24rpx;"></image>
      </view>
      <view>{{item.status_text}}</view>
    </view>
    <view class="package_sale space-between" style="background-color: #FFF4E7 ;">
      <view class="column">
        <view>发起人</view>
        <view>{{item.fa_user_name}}</view>
      </view>
      <view class="column">
        <view>加注量(公斤)</view>
        <view>{{item.amount}}</view>
      </view>
      <view class="column">
        <view>消费金额(元)</view>
        <view>{{item.money}}</view>
      </view>
    </view>
    <view style="color: #666;font-size: 26rpx;">发起时间：{{item.createtime}}</view>
  </view>
</template>

<script setup lang="ts">
  import { navTo } from '@/utils/navigator';
  import { copyText } from '@/utils/copyText';
  const props = defineProps({
    orderLists: {
      type: Array,
      default: [],
    },
  });
</script>

<style scoped lang="less">
  .column view:nth-of-type(1) {
    color: #666;
    font-size: 24rpx;
    margin-bottom: 8rpx;
  }

  .column view:nth-of-type(2) {
    font-weight: 500;
  }
</style>